//
//  codeViewController.m
//  Lesson
//
//  Created by centling on 15/4/15.
//  Copyright (c) 2015年 Seas.CHENG. All rights reserved.
//

#import "codeViewController.h"

@interface codeViewController ()

@end

@implementation codeViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.view.backgroundColor=[UIColor lightGrayColor];
    UIButton *button=[[UIButton alloc] initWithFrame:CGRectMake(100, 300, 100, 50)];
    button.backgroundColor=[UIColor blueColor];
    [button addTarget:self action:@selector(buttonClick:) forControlEvents:UIControlEventTouchDown];
    [self.view addSubview:button];
    // Do any additional setup after loading the view.
}


-(void)buttonClick:(id)sender{
    [self dismissViewControllerAnimated:YES completion:nil];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
